<?php
/**
 * <pre>
 * <b>RUBIK IT Solution & Development ltd.</b>
 *
 * PROJECT		: HOTSWEETDATES
 * COPYRIGHT	: 2009
 * ------------------------------------------------------
 * 
 * [GENERAL INFO OF THIS FILE] 
 * 
 * </pre>
 * 
 * Created on	:  Mar 20, 2009
 * 
 * @author		minhvn <minhvn@rubik.com.vn>
 * @access		[public/private]
 * @package	[package name]
 *
 */

defined ( '_FW_EXEC' ) or die ( 'Restricted access' );

RCoreImporter::cls('html.fieldInfo.BooleanHtmlFieldInfo');

class MultiBooleanHtmlFieldInfo extends BooleanHtmlFieldInfo {

	/**
	 * Function for geting the html for inputing data
	 * @return string
	 */
	function getHtmlInputData($dataType = '', $extAttribute = '') {
		$extAttribute .= $this->buildValidateHtmlAttribute($dataType);
		$value = htmlspecialchars($this->_value);
		if ($value) {
			$checkBox = 'checked="checked"';
		}
		$inputHtml = "<input {$checkBox} type=\"checkbox\" {$extAttribute} name=\"{$this->_fieldName}\" id=\"{$this->_fieldName}\" value=\"1\" />";
		return $inputHtml;
	}
}
?>